def rc_decode():
    n = input("请输入行数:")
    a = [i for i in input("请输入RC地址，以空格分隔:").split()]
    column = ""
    row = ""
    wei = ""
    res=None
    def shuzi(a):
        numbers = ""
        for char in a:
            if char.isdigit():
                numbers += char
        return numbers

    print(n)

    for b in a:
        for i in range(len(b)):
            if b[i]=="C":
                for j in range(i,len(b)):
                    column = column+b[j]
                break
            else:
                row = row+b[i]
        row = int(shuzi(row))
        column = int(shuzi(column))
        while column>=26:
            wei = chr((column-1)%26+65)+str(wei)
            column = column//26
        tou =chr((column - 1) % 26 + 65)
        column = tou +str(wei)
        shuchu = column + str(row)
        column = ""
        row = ""
        wei = ""
        print(shuchu)
        continue
    return res




